import api from './index'

// 用户端接口
export default {
	// 获取康复资讯列表
	fetchNewsList: (params) => api.get('/ba/article/list', params),
	// 康复资讯详情
	fetchNewsDetail: (params) => api.get('/ba/article/' + params.id),
	// 专家管理
	professorList: (params) => api.get('/ba/professor/list', params),
	// 专家详情
	professorDetail:(id) => api.get('/ba/professor/' + id),
	// 课程库
	videoList: (params) => api.get('/ba/video/listNoVip', params),
	//训练计划课程
	planVideoList: (params) => api.get('/ba/video/list', params),
	// 课程库详情
	videoDetail: (id) => api.get('/ba/video/' + id),
	// 辅具设备
	deviceList: (params) => api.get('/ba/device/list', params),
	// 辅具设备详情
	deviceDetail: (id) => api.get('/ba/device/' + id),
	// 下单收货地址列表
	fetchAddressList: (params) => api.get('/ba/address/list', params),
	// 收货地址详情
	fetchAddressDetail: (params) => api.get('/ba/address/' + params.id),
	// 新增收货地址
	addAddress: (params) => api.post('/ba/address', params),
	// 编辑收货地址
	editAddress: (params) => api.put('/ba/address', params),
	// 删除收货地址
	deleteAddress: (params) => api.delete('/ba/address/' + params.ids),
	// 设置收货地址为默认
	defaultAddress: (params) => api.post('/ba/address/editDefault', params),
	// 下单自提点列表
	fetchPickupList: (params) => api.get('/ba/pickup/list', params),
	// 获取普通/ 定制vip会员卡规则
	fetchCardList: (params) => api.get('/ba/cardrule/list', params),
	// 获取vip定制服务详情
	fetchVipDetail: (params) => api.get('/ba/cardrule/' + params.id),
	// 获取普通/ 定制vip会员卡购买记录列表
	fetchCardRecordList: (params) => api.get('/ba/card/list', params),
	// 新增病情信息
	addCase: (params) => api.post('/ba/case', params),
	// 查看病情报告详情
	fetchCaseDetail: (params) => api.get('/ba/case/getMedicineByMemberCardId', params),
	// 新增收藏
	addCollect: (params) => api.post('/ba/collect', params),
	// 收藏管理
	collectList: (params) => api.get('/ba/collect/list', params),
	// 删除收藏课程
	deleteCollect: (params) => api.delete('/ba/collect/' + params.ids),
	//取消收藏
	cancelCollect: (params) => api.post('/ba/collect/cancelCollect ', params), 
	// 评估报告
	reportList: (params) => api.get('/ba/report/list', params),
	// 评估报告详情
	reportDetail: (params) => api.get('/ba/report/getEvaluationReportDetail', params),
	// 订单列表
	orderList: (params) => api.get('/ba/order/list', params),
	// 订单详情
	fetchOrderDetail: (params) => api.get('/ba/order/' + params.id),
	//修改订单(确认收货)
	editOrder: (params) => api.put('/ba/order', params),
	// 新增反馈
	addFeedback: (params) => api.post('/ba/feedback', params),
	// 获取反馈详情
	getFeedbackDetail: (params) => api.get('/ba/feedback/getBaFeedbackDetail', params),
	// 康复训练计划列表
  fetchPlanList: (params) => api.get('/ba/plan/list', params),
	// 搜索接口
  fetchSearchList: (params) => api.get('/ba/search/list', params),
}